/**
 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package com.crossriver.crgis.database.model;

import com.liferay.portal.kernel.bean.AutoEscapeBeanHandler;
import com.liferay.portal.kernel.util.StringBundler;
import com.liferay.portal.model.impl.BaseModelImpl;

import java.io.Serializable;

import java.lang.reflect.Proxy;

import java.util.Date;

/**
 * @author Wole Adetiba
 */
public class Bank_Payment_SlipClp extends BaseModelImpl<Bank_Payment_Slip>
	implements Bank_Payment_Slip {
	public Bank_Payment_SlipClp() {
	}

	public String getPrimaryKey() {
		return _depSlipNo;
	}

	public void setPrimaryKey(String pk) {
		setDepSlipNo(pk);
	}

	public Serializable getPrimaryKeyObj() {
		return _depSlipNo;
	}

	public String getDepSlipNo() {
		return _depSlipNo;
	}

	public void setDepSlipNo(String depSlipNo) {
		_depSlipNo = depSlipNo;
	}

	public String getUserId() {
		return _userId;
	}

	public void setUserId(String userId) {
		_userId = userId;
	}

	public Date getRegistedDate() {
		return _registedDate;
	}

	public void setRegistedDate(Date registedDate) {
		_registedDate = registedDate;
	}

	public String getApplicationId() {
		return _applicationId;
	}

	public void setApplicationId(String applicationId) {
		_applicationId = applicationId;
	}

	public String getDepositorName() {
		return _depositorName;
	}

	public void setDepositorName(String depositorName) {
		_depositorName = depositorName;
	}

	public Double getPaidAmount() {
		return _paidAmount;
	}

	public void setPaidAmount(Double paidAmount) {
		_paidAmount = paidAmount;
	}

	public Double getApprovedAmount() {
		return _approvedAmount;
	}

	public void setApprovedAmount(Double approvedAmount) {
		_approvedAmount = approvedAmount;
	}

	public String getBankName() {
		return _bankName;
	}

	public void setBankName(String bankName) {
		_bankName = bankName;
	}

	public String getUploadDepositSlip() {
		return _uploadDepositSlip;
	}

	public void setUploadDepositSlip(String uploadDepositSlip) {
		_uploadDepositSlip = uploadDepositSlip;
	}

	public String getUploadDepositSlipFilename() {
		return _uploadDepositSlipFilename;
	}

	public void setUploadDepositSlipFilename(String uploadDepositSlipFilename) {
		_uploadDepositSlipFilename = uploadDepositSlipFilename;
	}

	public String getUploadDepositSlipDocName() {
		return _uploadDepositSlipDocName;
	}

	public void setUploadDepositSlipDocName(String uploadDepositSlipDocName) {
		_uploadDepositSlipDocName = uploadDepositSlipDocName;
	}

	public String getStatus() {
		return _status;
	}

	public void setStatus(String status) {
		_status = status;
	}

	public Bank_Payment_Slip toEscapedModel() {
		if (isEscapedModel()) {
			return this;
		}
		else {
			return (Bank_Payment_Slip)Proxy.newProxyInstance(Bank_Payment_Slip.class.getClassLoader(),
				new Class[] { Bank_Payment_Slip.class },
				new AutoEscapeBeanHandler(this));
		}
	}

	public Object clone() {
		Bank_Payment_SlipClp clone = new Bank_Payment_SlipClp();

		clone.setDepSlipNo(getDepSlipNo());
		clone.setUserId(getUserId());
		clone.setRegistedDate(getRegistedDate());
		clone.setApplicationId(getApplicationId());
		clone.setDepositorName(getDepositorName());
		clone.setPaidAmount(getPaidAmount());
		clone.setApprovedAmount(getApprovedAmount());
		clone.setBankName(getBankName());
		clone.setUploadDepositSlip(getUploadDepositSlip());
		clone.setUploadDepositSlipFilename(getUploadDepositSlipFilename());
		clone.setUploadDepositSlipDocName(getUploadDepositSlipDocName());
		clone.setStatus(getStatus());

		return clone;
	}

	public int compareTo(Bank_Payment_Slip bank_Payment_Slip) {
		int value = 0;

		value = getDepSlipNo().compareTo(bank_Payment_Slip.getDepSlipNo());

		if (value != 0) {
			return value;
		}

		return 0;
	}

	public boolean equals(Object obj) {
		if (obj == null) {
			return false;
		}

		Bank_Payment_SlipClp bank_Payment_Slip = null;

		try {
			bank_Payment_Slip = (Bank_Payment_SlipClp)obj;
		}
		catch (ClassCastException cce) {
			return false;
		}

		String pk = bank_Payment_Slip.getPrimaryKey();

		if (getPrimaryKey().equals(pk)) {
			return true;
		}
		else {
			return false;
		}
	}

	public int hashCode() {
		return getPrimaryKey().hashCode();
	}

	public String toString() {
		StringBundler sb = new StringBundler(25);

		sb.append("{depSlipNo=");
		sb.append(getDepSlipNo());
		sb.append(", userId=");
		sb.append(getUserId());
		sb.append(", registedDate=");
		sb.append(getRegistedDate());
		sb.append(", applicationId=");
		sb.append(getApplicationId());
		sb.append(", depositorName=");
		sb.append(getDepositorName());
		sb.append(", paidAmount=");
		sb.append(getPaidAmount());
		sb.append(", approvedAmount=");
		sb.append(getApprovedAmount());
		sb.append(", bankName=");
		sb.append(getBankName());
		sb.append(", uploadDepositSlip=");
		sb.append(getUploadDepositSlip());
		sb.append(", uploadDepositSlipFilename=");
		sb.append(getUploadDepositSlipFilename());
		sb.append(", uploadDepositSlipDocName=");
		sb.append(getUploadDepositSlipDocName());
		sb.append(", status=");
		sb.append(getStatus());
		sb.append("}");

		return sb.toString();
	}

	public String toXmlString() {
		StringBundler sb = new StringBundler(40);

		sb.append("<model><model-name>");
		sb.append("com.crossriver.crgis.database.model.Bank_Payment_Slip");
		sb.append("</model-name>");

		sb.append(
			"<column><column-name>depSlipNo</column-name><column-value><![CDATA[");
		sb.append(getDepSlipNo());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>userId</column-name><column-value><![CDATA[");
		sb.append(getUserId());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>registedDate</column-name><column-value><![CDATA[");
		sb.append(getRegistedDate());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>applicationId</column-name><column-value><![CDATA[");
		sb.append(getApplicationId());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>depositorName</column-name><column-value><![CDATA[");
		sb.append(getDepositorName());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>paidAmount</column-name><column-value><![CDATA[");
		sb.append(getPaidAmount());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>approvedAmount</column-name><column-value><![CDATA[");
		sb.append(getApprovedAmount());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>bankName</column-name><column-value><![CDATA[");
		sb.append(getBankName());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>uploadDepositSlip</column-name><column-value><![CDATA[");
		sb.append(getUploadDepositSlip());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>uploadDepositSlipFilename</column-name><column-value><![CDATA[");
		sb.append(getUploadDepositSlipFilename());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>uploadDepositSlipDocName</column-name><column-value><![CDATA[");
		sb.append(getUploadDepositSlipDocName());
		sb.append("]]></column-value></column>");
		sb.append(
			"<column><column-name>status</column-name><column-value><![CDATA[");
		sb.append(getStatus());
		sb.append("]]></column-value></column>");

		sb.append("</model>");

		return sb.toString();
	}

	private String _depSlipNo;
	private String _userId;
	private Date _registedDate;
	private String _applicationId;
	private String _depositorName;
	private Double _paidAmount;
	private Double _approvedAmount;
	private String _bankName;
	private String _uploadDepositSlip;
	private String _uploadDepositSlipFilename;
	private String _uploadDepositSlipDocName;
	private String _status;
}